﻿@model EventPlanner.Models.Evento

@{
    ViewBag.Title = "Editar Evento";
}
 <div class="subtitle">
<h2>@EventPlanner.Resources.Global.Global.lbl_EditarEvento</h2>
</div>
<p></p>

<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery-ui-1.8.11.js")" type="text/javascript"></script>

<script src="@Url.Content("~/Scripts/datePicker.js")" type="text/javascript"></script>
<link href="@Url.Content("~/Content/themes/base/jquery.ui.all.css")" rel="stylesheet" type="text/css" />

<script src="@Url.Content("~/Scripts/fechaValidation.js")" type="text/javascript"></script>

<script src="@Url.Content("~/Scripts/timePicker/jquery.ui.timepicker.js")" type="text/javascript"></script>
<link href="@Url.Content("~/Scripts/timePicker/jquery.ui.timepicker.css")" rel="stylesheet" type="text/css" />

@using (Html.BeginForm()) {
    @Html.ValidationSummary(true)
    <fieldset>
        <legend>@EventPlanner.Resources.Global.Global.lbl_Evento</legend>

        @Html.HiddenFor(model => model.id)
          @Html.HiddenFor(model => model.Creador)

        <div class="editor-label">
            @Html.LabelFor(model => model.Nombre)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Nombre)
            @Html.ValidationMessageFor(model => model.Nombre)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.Descripcion)
        </div>
        <div class="editor-field">
            @Html.TextAreaFor(model => model.Descripcion)
            @Html.ValidationMessageFor(model => model.Descripcion)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.Fecha)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Fecha)
            @Html.ValidationMessageFor(model => model.Fecha)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.Hora)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Hora)
            @Html.ValidationMessageFor(model => model.Hora)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.Lugar)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Lugar)
            @Html.ValidationMessageFor(model => model.Lugar)
        </div>
        <div class="editor-label">
            @Html.LabelFor(model => model.Cupo)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Cupo)
            @Html.ValidationMessageFor(model => model.Cupo)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.Organizador)
        </div>
        <div class="editor-field">
            @Html.DropDownListFor(model => model.OrganizadorId, (IEnumerable<SelectListItem>)ViewData["names"])
            @Html.ValidationMessageFor(model => model.Organizador)
        </div>
        <p>
            <input type="submit" value=@EventPlanner.Resources.Global.Global.lbl_Guardar />
        </p>
    </fieldset>
}

<div>
   <a href="@Html.Encode(Request.UrlReferrer.ToString())">@EventPlanner.Resources.Global.Global.lbl_VolverLista</a>
</div>
